package org.travel_system.service.impl;

import org.springframework.stereotype.Service;
import org.travel_system.mapper.ComplaintHandlingMapper;
import org.travel_system.pojo.ComplaintHandLing;
import org.travel_system.service.ComplaintHandlingService;

import java.util.List;

@Service
public class ComplaintHandlingServiceImpl implements ComplaintHandlingService {

    private final ComplaintHandlingMapper complaintHandlingMapper;

    public ComplaintHandlingServiceImpl(ComplaintHandlingMapper complaintHandlingMapper)
    {
        this.complaintHandlingMapper = complaintHandlingMapper;

    }

    @Override
    public List<ComplaintHandLing> getComplaintHandling(Integer complaintId) {
        return complaintHandlingMapper.getComplaintHandling(complaintId);
    }

    @Override
    public int addComplaintHandling(ComplaintHandLing complaintHandLing) {
        return complaintHandlingMapper.addComplaintHandling(complaintHandLing);
    }

    @Override
    public int deleteComplaintHandling(int handlingId) {
        return complaintHandlingMapper.deleteComplaintHandling(handlingId);
    }
}
